#include <stdio.h>
#include <stdlib.h>
#include <string.h>

typedef struct Student {
  int stu_id;
  char *name;
  char tel[11];
} Stu;

int insert_stu(Stu **p, int *nmemb, const Stu data);
int delete_stu(Stu **p, int *nmemb, const void *key,
               int (*cmp)(const void *data, const void *key));
void show_stu(const Stu *p, int nmemb);

int insert_stu(Stu **p, int *nmemb, const Stu data) {
  *p = realloc(*p, (*nmemb + 1) * sizeof(Stu));
  *p[*nmemb] = data;
  (*nmemb)++;
  return 1;
}

int delete_stu(Stu **p, int *nmemb, const void *key,
               int (*cmp)(const void *data, const void *key)) {
  for (int i = 0; i < (*nmemb) - 1; i++) {
  }
}
